#ifndef MSGSERVER_H
#define MSGSERVER_H

#include "absserver.h"

class MsgServer : public AbsServer
{
    Q_OBJECT
public:
    explicit MsgServer(QObject *parent = 0);
    ~MsgServer();

signals:
    void signalDownloadFile(const QJsonValue &json);

private:
    // 客户端管理
    QVector <MsgSocket *> m_clients;
public slots:
    void SltTransFileToClient(const int &userId, const QJsonValue &json);

private slots:
    void SltNewConnection();
    void SltConnected();
    void SltDisConnected();
    void SltMsgToClient(const quint8 &type, const int &id, const QJsonValue &json);
};

#endif // MSGSERVER_H
